"use strict";
var __assign = (this && this.__assign) || function () {
    __assign = Object.assign || function(t) {
        for (var s, i = 1, n = arguments.length; i < n; i++) {
            s = arguments[i];
            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
                t[p] = s[p];
        }
        return t;
    };
    return __assign.apply(this, arguments);
};
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    var desc = Object.getOwnPropertyDescriptor(m, k);
    if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
      desc = { enumerable: true, get: function() { return m[k]; } };
    }
    Object.defineProperty(o, k2, desc);
}) : (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    o[k2] = m[k];
}));
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
    Object.defineProperty(o, "default", { enumerable: true, value: v });
}) : function(o, v) {
    o["default"] = v;
});
var __importStar = (this && this.__importStar) || function (mod) {
    if (mod && mod.__esModule) return mod;
    var result = {};
    if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
    __setModuleDefault(result, mod);
    return result;
};
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
    function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
    return new (P || (P = Promise))(function (resolve, reject) {
        function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
        function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
        function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
        step((generator = generator.apply(thisArg, _arguments || [])).next());
    });
};
var __generator = (this && this.__generator) || function (thisArg, body) {
    var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
    return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
    function verb(n) { return function (v) { return step([n, v]); }; }
    function step(op) {
        if (f) throw new TypeError("Generator is already executing.");
        while (g && (g = 0, op[0] && (_ = 0)), _) try {
            if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
            if (y = 0, t) op = [op[0] & 2, t.value];
            switch (op[0]) {
                case 0: case 1: t = op; break;
                case 4: _.label++; return { value: op[1], done: false };
                case 5: _.label++; y = op[1]; op = [0]; continue;
                case 7: op = _.ops.pop(); _.trys.pop(); continue;
                default:
                    if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
                    if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
                    if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
                    if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
                    if (t[2]) _.ops.pop();
                    _.trys.pop(); continue;
            }
            op = body.call(thisArg, _);
        } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
        if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
    }
};
var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
    if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
        if (ar || !(i in from)) {
            if (!ar) ar = Array.prototype.slice.call(from, 0, i);
            ar[i] = from[i];
        }
    }
    return to.concat(ar || Array.prototype.slice.call(from));
};
var __importDefault = (this && this.__importDefault) || function (mod) {
    return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
var pictureController_1 = require("@/api/pictureController");
var ant_design_vue_1 = require("ant-design-vue");
var index_1 = require("@/utils/index");
var vue_1 = require("vue");
var vue_router_1 = require("vue-router");
var useLoginUserStore_1 = require("@/stores/useLoginUserStore");
var index_2 = require("../utils/index");
var icons_vue_1 = require("@ant-design/icons-vue");
var ShareModal_vue_1 = __importDefault(require("@/components/ShareModal.vue"));
var props = defineProps();
var picture = (0, vue_1.ref)({});
var loginUserStore = (0, useLoginUserStore_1.useLoginUserStore)();
var router = (0, vue_router_1.useRouter)();
// 获取图片详情  
var fetchPictureDetail = function () { return __awaiter(void 0, void 0, void 0, function () {
    var res, e_1;
    return __generator(this, function (_a) {
        switch (_a.label) {
            case 0:
                _a.trys.push([0, 2, , 3]);
                return [4 /*yield*/, (0, pictureController_1.getPictureVoByIdUsingGet)({
                        id: props.id,
                    })];
            case 1:
                res = _a.sent();
                if (res.data.code === 0 && res.data.data) {
                    picture.value = res.data.data;
                }
                else {
                    ant_design_vue_1.message.error('获取图片详情失败，' + res.data.message);
                }
                return [3 /*break*/, 3];
            case 2:
                e_1 = _a.sent();
                ant_design_vue_1.message.error('获取图片详情失败：' + e_1.message);
                return [3 /*break*/, 3];
            case 3: return [2 /*return*/];
        }
    });
}); };
(0, vue_1.onMounted)(function () {
    fetchPictureDetail();
});
// 是否具有编辑权限  
var canEdit = (0, vue_1.computed)(function () {
    var loginUser = loginUserStore.loginUser;
    // 未登录不可编辑  
    if (!loginUser.id) {
        return false;
    }
    // 仅本人或管理员可编辑  
    var user = picture.value.user || {};
    return loginUser.id === user.id || loginUser.userRole === 'admin';
});
// 编辑  
// 编辑
var doEdit = function () {
    router.push({
        path: '/add_picture',
        query: {
            id: picture.value.id,
            spaceId: picture.value.spaceId
        }
    });
};
// 删除  
var doDelete = function () { return __awaiter(void 0, void 0, void 0, function () {
    var id, res;
    return __generator(this, function (_a) {
        switch (_a.label) {
            case 0:
                id = picture.value.id;
                if (!id) {
                    return [2 /*return*/];
                }
                return [4 /*yield*/, (0, pictureController_1.deletePictureUsingPost)({ id: id })];
            case 1:
                res = _a.sent();
                if (res.data.code === 0) {
                    ant_design_vue_1.message.success('删除成功');
                }
                else {
                    ant_design_vue_1.message.error('删除失败');
                }
                return [2 /*return*/];
        }
    });
}); };
// 处理下载  
var doDownload = function () {
    (0, index_1.downloadImage)(picture.value.url);
};
// 分享
// ----- 分享操作 ----
var shareModalRef = (0, vue_1.ref)();
// 分享链接
var shareLink = (0, vue_1.ref)();
// 分享
var doShare = function () {
    shareLink.value = "".concat(window.location.protocol, "//").concat(window.location.host, "/picture/").concat(picture.value.id);
    if (shareModalRef.value) {
        shareModalRef.value.openModal();
    }
}; /* PartiallyEnd: #3632/scriptSetup.vue */
function __VLS_template() {
    var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
    var __VLS_ctx = {};
    var __VLS_components;
    var __VLS_directives;
    // CSS variable injection 
    // CSS variable injection end 
    __VLS_elementAsFunction(__VLS_intrinsicElements.div, __VLS_intrinsicElements.div)({
        id: ("pictureDetailPage"),
    });
    var __VLS_0 = {}.ARow;
    /** @type { [typeof __VLS_components.ARow, typeof __VLS_components.aRow, typeof __VLS_components.ARow, typeof __VLS_components.aRow, ] } */ ;
    // @ts-ignore
    var __VLS_1 = __VLS_asFunctionalComponent(__VLS_0, new __VLS_0({
        gutter: (([16, 16])),
    }));
    var __VLS_2 = __VLS_1.apply(void 0, __spreadArray([{
            gutter: (([16, 16])),
        }], __VLS_functionalComponentArgsRest(__VLS_1), false));
    var __VLS_6 = {}.ACol;
    /** @type { [typeof __VLS_components.ACol, typeof __VLS_components.aCol, typeof __VLS_components.ACol, typeof __VLS_components.aCol, ] } */ ;
    // @ts-ignore
    var __VLS_7 = __VLS_asFunctionalComponent(__VLS_6, new __VLS_6({
        sm: ((24)),
        md: ((16)),
        xl: ((18)),
    }));
    var __VLS_8 = __VLS_7.apply(void 0, __spreadArray([{
            sm: ((24)),
            md: ((16)),
            xl: ((18)),
        }], __VLS_functionalComponentArgsRest(__VLS_7), false));
    var __VLS_12 = {}.ACard;
    /** @type { [typeof __VLS_components.ACard, typeof __VLS_components.aCard, typeof __VLS_components.ACard, typeof __VLS_components.aCard, ] } */ ;
    // @ts-ignore
    var __VLS_13 = __VLS_asFunctionalComponent(__VLS_12, new __VLS_12({
        title: ("图片预览"),
    }));
    var __VLS_14 = __VLS_13.apply(void 0, __spreadArray([{
            title: ("图片预览"),
        }], __VLS_functionalComponentArgsRest(__VLS_13), false));
    var __VLS_18 = {}.AImage;
    /** @type { [typeof __VLS_components.AImage, typeof __VLS_components.aImage, ] } */ ;
    // @ts-ignore
    var __VLS_19 = __VLS_asFunctionalComponent(__VLS_18, new __VLS_18(__assign({ style: ({}) }, { src: ((__VLS_ctx.picture.url)) })));
    var __VLS_20 = __VLS_19.apply(void 0, __spreadArray([__assign({ style: ({}) }, { src: ((__VLS_ctx.picture.url)) })], __VLS_functionalComponentArgsRest(__VLS_19), false));
    __VLS_17.slots.default;
    var __VLS_17;
    __VLS_11.slots.default;
    var __VLS_11;
    var __VLS_24 = {}.ACol;
    /** @type { [typeof __VLS_components.ACol, typeof __VLS_components.aCol, typeof __VLS_components.ACol, typeof __VLS_components.aCol, ] } */ ;
    // @ts-ignore
    var __VLS_25 = __VLS_asFunctionalComponent(__VLS_24, new __VLS_24({
        sm: ((24)),
        md: ((8)),
        xl: ((6)),
    }));
    var __VLS_26 = __VLS_25.apply(void 0, __spreadArray([{
            sm: ((24)),
            md: ((8)),
            xl: ((6)),
        }], __VLS_functionalComponentArgsRest(__VLS_25), false));
    var __VLS_30 = {}.ACard;
    /** @type { [typeof __VLS_components.ACard, typeof __VLS_components.aCard, typeof __VLS_components.ACard, typeof __VLS_components.aCard, ] } */ ;
    // @ts-ignore
    var __VLS_31 = __VLS_asFunctionalComponent(__VLS_30, new __VLS_30({
        title: ("图片信息"),
    }));
    var __VLS_32 = __VLS_31.apply(void 0, __spreadArray([{
            title: ("图片信息"),
        }], __VLS_functionalComponentArgsRest(__VLS_31), false));
    var __VLS_36 = {}.ADescriptions;
    /** @type { [typeof __VLS_components.ADescriptions, typeof __VLS_components.aDescriptions, typeof __VLS_components.ADescriptions, typeof __VLS_components.aDescriptions, ] } */ ;
    // @ts-ignore
    var __VLS_37 = __VLS_asFunctionalComponent(__VLS_36, new __VLS_36({
        column: ((1)),
    }));
    var __VLS_38 = __VLS_37.apply(void 0, __spreadArray([{
            column: ((1)),
        }], __VLS_functionalComponentArgsRest(__VLS_37), false));
    var __VLS_42 = {}.ADescriptionsItem;
    /** @type { [typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, ] } */ ;
    // @ts-ignore
    var __VLS_43 = __VLS_asFunctionalComponent(__VLS_42, new __VLS_42({
        label: ("作者"),
    }));
    var __VLS_44 = __VLS_43.apply(void 0, __spreadArray([{
            label: ("作者"),
        }], __VLS_functionalComponentArgsRest(__VLS_43), false));
    var __VLS_48 = {}.ASpace;
    /** @type { [typeof __VLS_components.ASpace, typeof __VLS_components.aSpace, typeof __VLS_components.ASpace, typeof __VLS_components.aSpace, ] } */ ;
    // @ts-ignore
    var __VLS_49 = __VLS_asFunctionalComponent(__VLS_48, new __VLS_48({}));
    var __VLS_50 = __VLS_49.apply(void 0, __spreadArray([{}], __VLS_functionalComponentArgsRest(__VLS_49), false));
    var __VLS_54 = {}.AAvatar;
    /** @type { [typeof __VLS_components.AAvatar, typeof __VLS_components.aAvatar, ] } */ ;
    // @ts-ignore
    var __VLS_55 = __VLS_asFunctionalComponent(__VLS_54, new __VLS_54({
        size: ((24)),
        src: (((_a = __VLS_ctx.picture.user) === null || _a === void 0 ? void 0 : _a.userAvatar)),
    }));
    var __VLS_56 = __VLS_55.apply(void 0, __spreadArray([{
            size: ((24)),
            src: (((_b = __VLS_ctx.picture.user) === null || _b === void 0 ? void 0 : _b.userAvatar)),
        }], __VLS_functionalComponentArgsRest(__VLS_55), false));
    __VLS_elementAsFunction(__VLS_intrinsicElements.div, __VLS_intrinsicElements.div)({});
    ((_c = __VLS_ctx.picture.user) === null || _c === void 0 ? void 0 : _c.userName);
    __VLS_53.slots.default;
    var __VLS_53;
    __VLS_47.slots.default;
    var __VLS_47;
    var __VLS_60 = {}.ADescriptionsItem;
    /** @type { [typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, ] } */ ;
    // @ts-ignore
    var __VLS_61 = __VLS_asFunctionalComponent(__VLS_60, new __VLS_60({
        label: ("名称"),
    }));
    var __VLS_62 = __VLS_61.apply(void 0, __spreadArray([{
            label: ("名称"),
        }], __VLS_functionalComponentArgsRest(__VLS_61), false));
    ((_d = __VLS_ctx.picture.name) !== null && _d !== void 0 ? _d : '未命名');
    __VLS_65.slots.default;
    var __VLS_65;
    var __VLS_66 = {}.ADescriptionsItem;
    /** @type { [typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, ] } */ ;
    // @ts-ignore
    var __VLS_67 = __VLS_asFunctionalComponent(__VLS_66, new __VLS_66({
        label: ("简介"),
    }));
    var __VLS_68 = __VLS_67.apply(void 0, __spreadArray([{
            label: ("简介"),
        }], __VLS_functionalComponentArgsRest(__VLS_67), false));
    ((_e = __VLS_ctx.picture.introduction) !== null && _e !== void 0 ? _e : '-');
    __VLS_71.slots.default;
    var __VLS_71;
    var __VLS_72 = {}.ADescriptionsItem;
    /** @type { [typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, ] } */ ;
    // @ts-ignore
    var __VLS_73 = __VLS_asFunctionalComponent(__VLS_72, new __VLS_72({
        label: ("分类"),
    }));
    var __VLS_74 = __VLS_73.apply(void 0, __spreadArray([{
            label: ("分类"),
        }], __VLS_functionalComponentArgsRest(__VLS_73), false));
    ((_f = __VLS_ctx.picture.category) !== null && _f !== void 0 ? _f : '默认');
    __VLS_77.slots.default;
    var __VLS_77;
    var __VLS_78 = {}.ADescriptionsItem;
    /** @type { [typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, ] } */ ;
    // @ts-ignore
    var __VLS_79 = __VLS_asFunctionalComponent(__VLS_78, new __VLS_78({
        label: ("标签"),
    }));
    var __VLS_80 = __VLS_79.apply(void 0, __spreadArray([{
            label: ("标签"),
        }], __VLS_functionalComponentArgsRest(__VLS_79), false));
    for (var _i = 0, _m = __VLS_getVForSourceType((__VLS_ctx.picture.tags)); _i < _m.length; _i++) {
        var tag = _m[_i][0];
        var __VLS_84 = {}.ATag;
        /** @type { [typeof __VLS_components.ATag, typeof __VLS_components.aTag, typeof __VLS_components.ATag, typeof __VLS_components.aTag, ] } */ ;
        // @ts-ignore
        var __VLS_85 = __VLS_asFunctionalComponent(__VLS_84, new __VLS_84({
            key: ((tag)),
        }));
        var __VLS_86 = __VLS_85.apply(void 0, __spreadArray([{
                key: ((tag)),
            }], __VLS_functionalComponentArgsRest(__VLS_85), false));
        (tag);
        __VLS_89.slots.default;
        var __VLS_89;
    }
    __VLS_83.slots.default;
    var __VLS_83;
    var __VLS_90 = {}.ADescriptionsItem;
    /** @type { [typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, ] } */ ;
    // @ts-ignore
    var __VLS_91 = __VLS_asFunctionalComponent(__VLS_90, new __VLS_90({
        label: ("格式"),
    }));
    var __VLS_92 = __VLS_91.apply(void 0, __spreadArray([{
            label: ("格式"),
        }], __VLS_functionalComponentArgsRest(__VLS_91), false));
    ((_g = __VLS_ctx.picture.picFormat) !== null && _g !== void 0 ? _g : '-');
    __VLS_95.slots.default;
    var __VLS_95;
    var __VLS_96 = {}.ADescriptionsItem;
    /** @type { [typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, ] } */ ;
    // @ts-ignore
    var __VLS_97 = __VLS_asFunctionalComponent(__VLS_96, new __VLS_96({
        label: ("宽度"),
    }));
    var __VLS_98 = __VLS_97.apply(void 0, __spreadArray([{
            label: ("宽度"),
        }], __VLS_functionalComponentArgsRest(__VLS_97), false));
    ((_h = __VLS_ctx.picture.picWidth) !== null && _h !== void 0 ? _h : '-');
    __VLS_101.slots.default;
    var __VLS_101;
    var __VLS_102 = {}.ADescriptionsItem;
    /** @type { [typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, ] } */ ;
    // @ts-ignore
    var __VLS_103 = __VLS_asFunctionalComponent(__VLS_102, new __VLS_102({
        label: ("高度"),
    }));
    var __VLS_104 = __VLS_103.apply(void 0, __spreadArray([{
            label: ("高度"),
        }], __VLS_functionalComponentArgsRest(__VLS_103), false));
    ((_j = __VLS_ctx.picture.picHeight) !== null && _j !== void 0 ? _j : '-');
    __VLS_107.slots.default;
    var __VLS_107;
    var __VLS_108 = {}.ADescriptionsItem;
    /** @type { [typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, ] } */ ;
    // @ts-ignore
    var __VLS_109 = __VLS_asFunctionalComponent(__VLS_108, new __VLS_108({
        label: ("宽高比"),
    }));
    var __VLS_110 = __VLS_109.apply(void 0, __spreadArray([{
            label: ("宽高比"),
        }], __VLS_functionalComponentArgsRest(__VLS_109), false));
    ((_k = __VLS_ctx.picture.picScale) !== null && _k !== void 0 ? _k : '-');
    __VLS_113.slots.default;
    var __VLS_113;
    var __VLS_114 = {}.ADescriptionsItem;
    /** @type { [typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, ] } */ ;
    // @ts-ignore
    var __VLS_115 = __VLS_asFunctionalComponent(__VLS_114, new __VLS_114({
        label: ("大小"),
    }));
    var __VLS_116 = __VLS_115.apply(void 0, __spreadArray([{
            label: ("大小"),
        }], __VLS_functionalComponentArgsRest(__VLS_115), false));
    (__VLS_ctx.formatSize(__VLS_ctx.picture.picSize));
    __VLS_119.slots.default;
    var __VLS_119;
    var __VLS_120 = {}.ADescriptionsItem;
    /** @type { [typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, typeof __VLS_components.ADescriptionsItem, typeof __VLS_components.aDescriptionsItem, ] } */ ;
    // @ts-ignore
    var __VLS_121 = __VLS_asFunctionalComponent(__VLS_120, new __VLS_120({
        label: ("主色调"),
    }));
    var __VLS_122 = __VLS_121.apply(void 0, __spreadArray([{
            label: ("主色调"),
        }], __VLS_functionalComponentArgsRest(__VLS_121), false));
    var __VLS_126 = {}.ASpace;
    /** @type { [typeof __VLS_components.ASpace, typeof __VLS_components.aSpace, typeof __VLS_components.ASpace, typeof __VLS_components.aSpace, ] } */ ;
    // @ts-ignore
    var __VLS_127 = __VLS_asFunctionalComponent(__VLS_126, new __VLS_126({}));
    var __VLS_128 = __VLS_127.apply(void 0, __spreadArray([{}], __VLS_functionalComponentArgsRest(__VLS_127), false));
    ((_l = __VLS_ctx.picture.picColor) !== null && _l !== void 0 ? _l : '-');
    if (__VLS_ctx.picture.picColor) {
        __VLS_elementAsFunction(__VLS_intrinsicElements.div)(__assign({ style: (({
                backgroundColor: __VLS_ctx.toHexColor(__VLS_ctx.picture.picColor),
                width: '16px',
                height: '16px',
            })) }));
    }
    __VLS_131.slots.default;
    var __VLS_131;
    __VLS_125.slots.default;
    var __VLS_125;
    __VLS_41.slots.default;
    var __VLS_41;
    var __VLS_132 = {}.ASpace;
    /** @type { [typeof __VLS_components.ASpace, typeof __VLS_components.aSpace, typeof __VLS_components.ASpace, typeof __VLS_components.aSpace, ] } */ ;
    // @ts-ignore
    var __VLS_133 = __VLS_asFunctionalComponent(__VLS_132, new __VLS_132({
        wrap: (true),
    }));
    var __VLS_134 = __VLS_133.apply(void 0, __spreadArray([{
            wrap: (true),
        }], __VLS_functionalComponentArgsRest(__VLS_133), false));
    if (__VLS_ctx.canEdit) {
        var __VLS_138 = {}.AButton;
        /** @type { [typeof __VLS_components.AButton, typeof __VLS_components.aButton, typeof __VLS_components.AButton, typeof __VLS_components.aButton, ] } */ ;
        // @ts-ignore
        var __VLS_139 = __VLS_asFunctionalComponent(__VLS_138, new __VLS_138(__assign({ 'onClick': {} }, { type: ("default") })));
        var __VLS_140 = __VLS_139.apply(void 0, __spreadArray([__assign({ 'onClick': {} }, { type: ("default") })], __VLS_functionalComponentArgsRest(__VLS_139), false));
        var __VLS_144 = void 0;
        var __VLS_145 = {
            onClick: (__VLS_ctx.doEdit)
        };
        var __VLS_141 = void 0;
        var __VLS_142 = void 0;
        __VLS_elementAsFunction(__VLS_intrinsicElements.template, __VLS_intrinsicElements.template)({});
        {
            var __VLS_thisSlot = __VLS_143.slots.icon;
            var __VLS_146 = {}.EditOutlined;
            /** @type { [typeof __VLS_components.EditOutlined, ] } */ ;
            // @ts-ignore
            var __VLS_147 = __VLS_asFunctionalComponent(__VLS_146, new __VLS_146({}));
            var __VLS_148 = __VLS_147.apply(void 0, __spreadArray([{}], __VLS_functionalComponentArgsRest(__VLS_147), false));
        }
        var __VLS_143;
    }
    if (__VLS_ctx.canEdit) {
        var __VLS_152 = {}.AButton;
        /** @type { [typeof __VLS_components.AButton, typeof __VLS_components.aButton, typeof __VLS_components.AButton, typeof __VLS_components.aButton, ] } */ ;
        // @ts-ignore
        var __VLS_153 = __VLS_asFunctionalComponent(__VLS_152, new __VLS_152(__assign({ 'onClick': {} }, { danger: (true) })));
        var __VLS_154 = __VLS_153.apply(void 0, __spreadArray([__assign({ 'onClick': {} }, { danger: (true) })], __VLS_functionalComponentArgsRest(__VLS_153), false));
        var __VLS_158 = void 0;
        var __VLS_159 = {
            onClick: (__VLS_ctx.doDelete)
        };
        var __VLS_155 = void 0;
        var __VLS_156 = void 0;
        __VLS_elementAsFunction(__VLS_intrinsicElements.template, __VLS_intrinsicElements.template)({});
        {
            var __VLS_thisSlot = __VLS_157.slots.icon;
            var __VLS_160 = {}.DeleteOutlined;
            /** @type { [typeof __VLS_components.DeleteOutlined, ] } */ ;
            // @ts-ignore
            var __VLS_161 = __VLS_asFunctionalComponent(__VLS_160, new __VLS_160({}));
            var __VLS_162 = __VLS_161.apply(void 0, __spreadArray([{}], __VLS_functionalComponentArgsRest(__VLS_161), false));
        }
        var __VLS_157;
    }
    var __VLS_166 = {}.AButton;
    /** @type { [typeof __VLS_components.AButton, typeof __VLS_components.aButton, typeof __VLS_components.AButton, typeof __VLS_components.aButton, ] } */ ;
    // @ts-ignore
    var __VLS_167 = __VLS_asFunctionalComponent(__VLS_166, new __VLS_166(__assign({ 'onClick': {} }, { type: ("primary") })));
    var __VLS_168 = __VLS_167.apply(void 0, __spreadArray([__assign({ 'onClick': {} }, { type: ("primary") })], __VLS_functionalComponentArgsRest(__VLS_167), false));
    var __VLS_172;
    var __VLS_173 = {
        onClick: (__VLS_ctx.doDownload)
    };
    var __VLS_169;
    var __VLS_170;
    __VLS_elementAsFunction(__VLS_intrinsicElements.template, __VLS_intrinsicElements.template)({});
    {
        var __VLS_thisSlot = __VLS_171.slots.icon;
        var __VLS_174 = {}.DownloadOutlined;
        /** @type { [typeof __VLS_components.DownloadOutlined, ] } */ ;
        // @ts-ignore
        var __VLS_175 = __VLS_asFunctionalComponent(__VLS_174, new __VLS_174({}));
        var __VLS_176 = __VLS_175.apply(void 0, __spreadArray([{}], __VLS_functionalComponentArgsRest(__VLS_175), false));
    }
    var __VLS_171;
    var __VLS_180 = {}.AButton;
    /** @type { [typeof __VLS_components.AButton, typeof __VLS_components.aButton, typeof __VLS_components.AButton, typeof __VLS_components.aButton, ] } */ ;
    // @ts-ignore
    var __VLS_181 = __VLS_asFunctionalComponent(__VLS_180, new __VLS_180(__assign({ 'onClick': {} }, { type: ("primary"), ghost: (true) })));
    var __VLS_182 = __VLS_181.apply(void 0, __spreadArray([__assign({ 'onClick': {} }, { type: ("primary"), ghost: (true) })], __VLS_functionalComponentArgsRest(__VLS_181), false));
    var __VLS_186;
    var __VLS_187 = {
        onClick: (__VLS_ctx.doShare)
    };
    var __VLS_183;
    var __VLS_184;
    __VLS_elementAsFunction(__VLS_intrinsicElements.template, __VLS_intrinsicElements.template)({});
    {
        var __VLS_thisSlot = __VLS_185.slots.icon;
        var __VLS_188 = {}.ShareAltOutlined;
        /** @type { [typeof __VLS_components.ShareAltOutlined, typeof __VLS_components.shareAltOutlined, ] } */ ;
        // @ts-ignore
        var __VLS_189 = __VLS_asFunctionalComponent(__VLS_188, new __VLS_188({}));
        var __VLS_190 = __VLS_189.apply(void 0, __spreadArray([{}], __VLS_functionalComponentArgsRest(__VLS_189), false));
    }
    var __VLS_185;
    __VLS_137.slots.default;
    var __VLS_137;
    __VLS_35.slots.default;
    var __VLS_35;
    __VLS_29.slots.default;
    var __VLS_29;
    __VLS_5.slots.default;
    var __VLS_5;
    // @ts-ignore
    /** @type { [typeof ShareModal, ] } */ ;
    // @ts-ignore
    var __VLS_194 = __VLS_asFunctionalComponent(ShareModal_vue_1.default, new ShareModal_vue_1.default({
        ref: ("shareModalRef"),
        link: ((__VLS_ctx.shareLink)),
    }));
    var __VLS_195 = __VLS_194.apply(void 0, __spreadArray([{
            ref: ("shareModalRef"),
            link: ((__VLS_ctx.shareLink)),
        }], __VLS_functionalComponentArgsRest(__VLS_194), false));
    // @ts-ignore navigation for `const shareModalRef = ref()`
    /** @type { typeof __VLS_ctx.shareModalRef } */ ;
    var __VLS_199 = {};
    var __VLS_198;
    var __VLS_slots;
    var $slots;
    var __VLS_inheritedAttrs;
    var $attrs;
    var __VLS_refs = {
        'shareModalRef': __VLS_199,
    };
    var $refs;
    var $el;
    return {
        attrs: {},
        slots: __VLS_slots,
        refs: $refs,
        rootEl: $el,
    };
}
;
var __VLS_self = (await Promise.resolve().then(function () { return __importStar(require('vue')); })).defineComponent({
    setup: function () {
        return {
            formatSize: index_1.formatSize,
            toHexColor: index_2.toHexColor,
            DeleteOutlined: icons_vue_1.DeleteOutlined,
            EditOutlined: icons_vue_1.EditOutlined,
            ShareAltOutlined: icons_vue_1.ShareAltOutlined,
            ShareModal: ShareModal_vue_1.default,
            picture: picture,
            canEdit: canEdit,
            doEdit: doEdit,
            doDelete: doDelete,
            doDownload: doDownload,
            shareModalRef: shareModalRef,
            shareLink: shareLink,
            doShare: doShare,
        };
    },
    __typeProps: {},
});
exports.default = (await Promise.resolve().then(function () { return __importStar(require('vue')); })).defineComponent({
    setup: function () {
        return {};
    },
    __typeProps: {},
    __typeRefs: {},
    __typeEl: {},
});
; /* PartiallyEnd: #4569/main.vue */
